package cn.iocoder.yudao.module.energy.controller.admin.device.vo;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import java.math.BigDecimal;

/**
 * 能耗设备 Base VO，提供给添加、修改、详细的子 VO 使用
 */
@Data
public class EnergyDeviceBaseVO {

    @Schema(description = "设备ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "DEV-001")
    @NotEmpty(message = "设备ID不能为空")
    private String deviceId;

    @Schema(description = "设备名称", requiredMode = Schema.RequiredMode.REQUIRED, example = "配电箱A")
    @NotEmpty(message = "设备名称不能为空")
    private String deviceName;

    @Schema(description = "设备型号", requiredMode = Schema.RequiredMode.REQUIRED, example = "DX-100A")
    @NotEmpty(message = "设备型号不能为空")
    private String model;

    @Schema(description = "安装位置", requiredMode = Schema.RequiredMode.REQUIRED, example = "主楼/5层/501室/东南角")
    @NotEmpty(message = "安装位置不能为空")
    private String location;

    @Schema(description = "能耗类型", requiredMode = Schema.RequiredMode.REQUIRED, example = "electricity")
    @NotEmpty(message = "能耗类型不能为空")
    private String energyType;

    @Schema(description = "标准电压(V)", example = "220.00")
    private BigDecimal voltage;

    @Schema(description = "标准电流(A)", example = "10.00")
    private BigDecimal currents;

    @Schema(description = "标准功率(kW)", example = "2.20")
    private BigDecimal activePower;

    @Schema(description = "累计能耗(kWh)", example = "100.50")
    private BigDecimal energyConsumption;

    @Schema(description = "设备温度(℃)", example = "35.50")
    private BigDecimal temperature;

    @Schema(description = "状态", example = "normal")
    private String status;

} 